<?php
    /**
      * Front index controller
      * @package M2 Micro Framework
      * @subpackage Main
      * @author Alexander Chaika
      */

    // Simple ACL hook for file system
    define('M2_MICRO', 1);

    // get engine
    include 'bootstrap.php';

    // get mvc controller and dispatch data
    $controller = new Controller();
    $controller->dispatch();

    // close DB connection, clean message stack and die
    Database::getInstance()->close();
    Message::getInstance()->clean();
    die;
?>